package source.table;

import source.kernel.DB;
import source.kernel.base.Table;

import java.sql.SQLException;
import java.util.List;

/**
 * @author Hai Thomson
 */
public class items extends Table {
	public items() {
		super("items", "itemid");
	}

	public List fetchItem(String applicationid) throws SQLException {
		String sql = "SELECT * FROM items, items_applications WHERE items.itemid = items_applications.itemid and items_applications.applicationid = ?";
		return DB.queryMapList(sql, applicationid);
	}
}
